package com.ruoyi.system.util;
import java.util.Random;
import java.util.UUID;
/**
 * @ClassName: StirngUtil
 * @Description TODO
 * @Author: lingzhi
 * @Description:
 * @Date: Created in  2024/3/30  22:25
 */
public class  StirngUtil{

        public static String generateRandomString(int length) {
            String characters = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890";
            StringBuilder sb = new StringBuilder();
            Random random = new Random();

            for (int i = 0; i < length; i++) {
                int index = random.nextInt(characters.length());
                sb.append(characters.charAt(index));
            }

            return sb.toString();
        }

}
